1
00:00:00,330 --> 00:00:02,770
So we have two things we want to address.

2
00:00:02,790 --> 00:00:09,920
One, we don't have enough spawn locations and the zombies are stacking, so that's easy enough to fix.

3
00:00:09,930 --> 00:00:11,880
Let's go to our workspace.

4
00:00:11,970 --> 00:00:17,370
And I called them spawn locations and there's four of them.

5
00:00:17,370 --> 00:00:18,480
They're invisible.

6
00:00:18,750 --> 00:00:19,430
That's all right.

7
00:00:19,440 --> 00:00:22,200
When we select them, we can see the outline.

8
00:00:23,210 --> 00:00:23,910
Cool.

9
00:00:23,930 --> 00:00:28,370
With the collisions off, I'm going to hit control D to duplicate those.

10
00:00:29,540 --> 00:00:33,740
And I will spread these out maybe this way a little bit.

11
00:00:35,330 --> 00:00:36,710
Maybe that way.

12
00:00:37,540 --> 00:00:38,950
And then I'll do another one.

13
00:00:38,950 --> 00:00:43,150
Control D duplicates more one.

14
00:00:43,980 --> 00:00:44,810
Sue.

15
00:00:44,820 --> 00:00:46,830
Let's see where they're all at.

16
00:00:46,830 --> 00:00:51,540
So I'm going to select the top one and then shift click the bottom one.

17
00:00:51,660 --> 00:00:52,540
There we go.

18
00:00:52,560 --> 00:00:54,630
There's our spawn locations.

19
00:00:55,790 --> 00:00:57,120
That should be pretty good.

20
00:00:57,140 --> 00:00:59,420
This one in the rock will be fine.

21
00:01:01,590 --> 00:01:02,900
Let's try it out.

22
00:01:02,910 --> 00:01:09,050
Well, let's get a weapon, too, because we also want to clear the zombies to see when we hit zero,

23
00:01:09,060 --> 00:01:13,320
we we're going to spawn new ones and not before.

24
00:01:15,360 --> 00:01:18,840
So I'm going to show you how to make weapons later in the course.

25
00:01:18,840 --> 00:01:21,720
But for now, let's go to our tool box.

26
00:01:22,170 --> 00:01:24,450
And under models, I'm going to search for laser.

27
00:01:25,230 --> 00:01:27,090
And these hyper lasers work pretty good.

28
00:01:27,090 --> 00:01:29,130
You could search on hyper laser fast.

29
00:01:29,130 --> 00:01:30,390
Hyper laser gun.

30
00:01:31,230 --> 00:01:32,810
Let's just move that there.

31
00:01:32,830 --> 00:01:34,840
It warns you that there's scripts.

32
00:01:34,840 --> 00:01:39,520
I typically don't use things with scripts from the toolbox, but I will for testing.

33
00:01:39,520 --> 00:01:42,550
I just I don't do it for my my production game.

34
00:01:43,060 --> 00:01:43,690
There we go.

35
00:01:43,690 --> 00:01:46,090
I just don't trust what's in other people's scripts.

36
00:01:46,330 --> 00:01:46,570
All right.

37
00:01:46,570 --> 00:01:48,100
So I got my hyper laser.

38
00:01:48,100 --> 00:01:53,080
I'm going to drag it down to starter pack.

39
00:01:53,080 --> 00:01:54,670
So it is in my backpack.

40
00:01:54,820 --> 00:01:57,970
When we start the game, we're going to keep an eye on zombies.

41
00:01:57,970 --> 00:02:01,240
When we get our ten, we'll kill them off.

42
00:02:01,240 --> 00:02:05,110
And then when there's nothing in here, we should spawn new zombies.

43
00:02:05,110 --> 00:02:09,790
But I think I'm going to put a print statement in my wave loop.

44
00:02:09,790 --> 00:02:11,230
So go to your wave loop.

45
00:02:12,130 --> 00:02:14,140
I'm going to print the number of zombies.

46
00:02:14,140 --> 00:02:14,620
Right?

47
00:02:14,620 --> 00:02:15,610
So I'm going to say.

48
00:02:17,190 --> 00:02:20,820
Current number of zombies.

49
00:02:21,390 --> 00:02:23,370
And that's going to be the count, right?

50
00:02:24,180 --> 00:02:27,270
DT Just to make sure that that number makes sense.

51
00:02:27,600 --> 00:02:30,780
And I'll go here to view output.

52
00:02:30,780 --> 00:02:32,280
So we see the output window.

53
00:02:32,310 --> 00:02:33,720
I'll make that a little bigger.

54
00:02:34,020 --> 00:02:36,210
Let's go ahead and do a play.

55
00:02:36,600 --> 00:02:42,090
Go to your game and then play here so we don't have to run all the way over there.

56
00:02:44,090 --> 00:02:46,730
Now, remember, we have a five second delay.

57
00:02:48,440 --> 00:02:52,220
Starting with current number of zombies is zero.

58
00:02:53,820 --> 00:02:55,790
That'll change fast enough, right?

59
00:02:56,180 --> 00:02:58,010
So we're not getting the stocking.

60
00:02:58,010 --> 00:02:58,820
That's pretty good.

61
00:02:58,820 --> 00:03:02,900
I mean, we could get some stocking, but we probably won't.

62
00:03:03,500 --> 00:03:05,180
All right, We have ten zombies.

63
00:03:05,180 --> 00:03:06,580
We shouldn't be getting any more.

64
00:03:06,590 --> 00:03:08,810
Let's go ahead and kill some of these zombies.

65
00:03:11,480 --> 00:03:12,100
Here we go.

66
00:03:12,110 --> 00:03:14,480
We're down to seven.

67
00:03:15,250 --> 00:03:16,210
Stop moving around.

68
00:03:16,570 --> 00:03:17,110
There we go.

69
00:03:17,140 --> 00:03:17,920
We got another one.

70
00:03:17,950 --> 00:03:21,400
Got another two down to five.

71
00:03:21,940 --> 00:03:23,800
All of you that I got three on one.

72
00:03:23,800 --> 00:03:25,510
So we're down to one zombie.

73
00:03:31,420 --> 00:03:32,470
Bam.

74
00:03:33,300 --> 00:03:34,830
Starting wave.

75
00:03:35,650 --> 00:03:36,940
Oh, here they come.

76
00:03:38,110 --> 00:03:39,340
That's looking good.

77
00:03:40,480 --> 00:03:41,150
That's looking good.

78
00:03:41,180 --> 00:03:46,180
It looks like we have some waves coming now, and we're controlling our numbers.